package cn.tedu.front.details.controller;

import cn.tedu.common.web.JsonResult;
import cn.tedu.front.details.pojo.vo.CarouselVO;
import cn.tedu.front.details.service.CarouselService;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@Api(tags = "轮播图")
@RequestMapping("/carousel")
public class CarouselController {
    @Autowired
    CarouselService service;

    @ApiOperation("获取轮播图")
    @ApiOperationSupport(order = 200)
    @GetMapping("/get-all")
    public JsonResult getAllCarousel(){
        List<CarouselVO> carousel = service.getCarousel();
        return JsonResult.ok("asdfjlkasjdflkjasdlkfjlasdkf");
    }
}
